package com.quanta.edaily.Service.impl;

import com.quanta.edaily.Service.HahaService;
import com.quanta.edaily.mapper.HahaMapper;
import com.quanta.edaily.pojo.Haha;
import jakarta.annotation.Resource;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class HahaServiceImpl implements HahaService {
    @Resource
    HahaMapper hahaMapper;
    @Override
    public int insert(Haha haha) {
        return hahaMapper.insert(haha);
    }

    @Override
    public int deleteById(Integer id) {
        return hahaMapper.deleteById(id);
    }

    @Override
    public int updateById(Haha haha) {
        return hahaMapper.updateById(haha);
    }

    @Override
    public Haha getById(Integer id) {
        return hahaMapper.getById(id);
    }

    @Override
    public List<Haha> getSome(Integer pageNum, Integer pageSize, String title) {
        return hahaMapper.getSome(pageNum,pageSize,title);
    }
}
